<?php
use yii\helpers\Url;
?>
<section class="vbox">
	<section class="scrollable wrapper">
		<div class="m-b-md">
			<h3 class="m-b-none">选择项目</h3>
		</div>
		<div class="row">
			<div class="col-lg-12">
				<section class="panel panel-default pos-rlt clearfix">
					<header class="panel-heading">
						<ul class="nav nav-pills pull-left">
							<li>
								<a href="javascript:void(0);" class="panel-toggle text-muted"><i class="fa fa-caret-down text-active"></i><i class="fa fa-caret-up text"></i></a>
							</li>
						</ul>
						<i style="margin-left: 15px; font-style: normal;"><?php echo Yii::$app->params['logic_config']['env_1'];?></i>
					</header>
					<div class="panel-body clearfix">
						<?php foreach ($projects as $project): ?>
							<?php if ($project['level'] == \app\models\ProjectModel::ENV_DEV): ?>
								<a href="<?php echo Url::toRoute(['available/add', 'id' => $project['id']]);?>" class="btn btn-s-md btn-dark" data-toggle="tooltip" data-placement="top" title="点击此按钮可提交上线单"><?php echo $project['name'];?></a>
							<?php endif;?>
						<?php endforeach;?>
					</div>
				</section>
				<section class="panel panel-default pos-rlt clearfix">
					<header class="panel-heading">
						<ul class="nav nav-pills pull-left">
							<li>
								<a href="javascript:void(0);" class="panel-toggle text-muted"><i class="fa fa-caret-down text-active"></i><i class="fa fa-caret-up text"></i></a>
							</li>
						</ul>
						<i style="margin-left: 15px; font-style: normal;"><?php echo Yii::$app->params['logic_config']['env_2'];?></i>
					</header>
					<div class="panel-body clearfix">
						<?php foreach ($projects as $project): ?>
							<?php if ($project['level'] == \app\models\ProjectModel::ENV_PROD): ?>
								<a href="<?php echo Url::toRoute(['available/add', 'id' => $project['id']]);?>" class="btn btn-s-md btn-warning" data-toggle="tooltip" data-placement="top" title="点击此按钮可提交上线单"><?php echo $project['name'];?></a>
							<?php endif;?>
						<?php endforeach;?>
					</div>
				</section>
				<section class="panel panel-default pos-rlt clearfix">
					<header class="panel-heading">
						<ul class="nav nav-pills pull-left">
							<li>
								<a href="javascript:void(0);" class="panel-toggle text-muted"><i class="fa fa-caret-down text-active"></i><i class="fa fa-caret-up text"></i></a>
							</li>
						</ul>
						<i style="margin-left: 15px; font-style: normal;"><?php echo Yii::$app->params['logic_config']['env_3'];?></i>
					</header>
					<div class="panel-body clearfix">
						<?php foreach ($projects as $project): ?>
							<?php if ($project['level'] == \app\models\ProjectModel::ENV_ONLINE): ?>
								<a href="<?php echo Url::toRoute(['available/add', 'id' => $project['id']]);?>" class="btn btn-s-md btn-success" data-toggle="tooltip" data-placement="top" title="点击此按钮可提交上线单"><?php echo $project['name'];?></a>
							<?php endif;?>
						<?php endforeach;?>


					</div>
				</section>
			</div>
		</div>
	</section>
</section>